<div class="nav-view form-group">{{component.title}}</div>
<div class="view form-group" ng-class="{'fb-hidden': component.properties.visible=='hidden'}">
	<label for="{{component.properties.overrideId}}" class="control-label">{{component.properties.label}}</label>
	<div ng-style="component.properties.style">
		<input type="hidden" fb-dynamic-model="component.properties.overrideId" fb-dynamic-model-pre="data" validator-required="{{component.properties.required}}" validator>
		
		<div class="row" ng-init="component.arrayValue[0]={};component.arrayValue[0].children = component.properties.treeOptions">
			<div ng-if="component.properties.selectPlugin==''" class="{{'col-xs-'+ 12/component.properties.level}}" 
				ng-repeat="num in [1,2,3,4,5,6]" > 
				<select class="form-control" ng-if="num<=component.properties.level" ng-disabled="component.properties.visible=='disabled'"
					ng-init="component.arrayValue[$index+1]=component.arrayValue[$index+1]==null?component.arrayValue[$index].children[0]:component.arrayValue[$index+1]"
					ng-change="component.arrayValue[$index+2]=component.arrayValue[$index+1].children[0]"
					ng-options="option.text for option in component.arrayValue[$index].children" 
					ng-model="component.arrayValue[$index+1]">
				</select>
			</div>
          
          	<div ng-if="component.properties.selectPlugin=='chosen'" class="{{'col-xs-'+ 12/component.properties.level}}" 
          		ng-repeat="num in [1,2,3,4,5,6]"> 
				<select chosen class="form-control" ng-if="num<=component.properties.level" ng-disabled="component.properties.visible=='disabled'" 
					placeholder-text-single="'选择一个选项'"
					no-results-text = "'没有结果匹配'"
					ng-init="component.arrayValue[$index+1]=component.arrayValue[$index+1]==null?component.arrayValue[$index].children[0]:component.arrayValue[$index+1]"
					ng-change="component.arrayValue[$index+2]=component.arrayValue[$index+1].children[0]"
					ng-options="option.text for option in component.arrayValue[$index].children" 
		            ng-model="component.arrayValue[$index+1]">
				</select>
			</div>
			
		</div>
		<p class="help-block">{{component.properties.description}}</p>
	</div>
</div>